package Endpoint;

import java.util.HashMap;
import java.util.Map;

import javax.xml.namespace.QName;
import javax.xml.ws.Endpoint;

import edit.EditEntreprise;

public class MonEndpoint {
	
	public static void main(String[] args) {
		Endpoint endpoint = Endpoint.create(new EditEntreprise());
		//Endpoint endpoint = Endpoint.create(new Service2());
		//Endpoint endpoint2 = Endpoint.create(new Service2());

		Map<String, Object> map = new HashMap<String, Object>();
		map.put(Endpoint.WSDL_SERVICE, new QName("http://localhost:8080/message", "editEntrepriseService"));
		map.put(Endpoint.WSDL_PORT, new QName("http://localhost:8080/message", "editEntreprisePort"));
 
		endpoint.setProperties(map);
		endpoint.publish("http://localhost:8080/message");
 
		try {
			Thread.sleep(1000);
		} catch (InterruptedException ie) { }
		
		endpoint.stop();
	}

	MonEndpoint() {
		
	}
	
}
